package com.feishi.core.util.common.rbtree;

import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: caixq
 * Date: 2020-07-08
 * Time: 下午3:01
 */
@Data
@NoArgsConstructor
public class RBTreeNode<T extends Comparable<T>> {
    private final boolean RED = false;
    private final boolean BLACK = true;
    private T key;
    private boolean color;
    private RBTreeNode<T> left;
    private RBTreeNode<T> right;
    private RBTreeNode<T> parent;

    public RBTreeNode(T key) {
        this.key = key;
        this.color = RED;
    }

}
